package com.own.core.html.modal;

import org.apache.wicket.ajax.AjaxRequestTarget;
import org.apache.wicket.markup.html.form.Form;

import com.own.core.html.form.OwnForm;
import com.own.core.html.form.button.OwnAjaxButton;
import com.own.core.html.panel.OwnPanel;

public class ActionPanel extends OwnPanel {

	public ActionPanel() {
	}

	public ActionPanel(String id) {
		super(id);
		OwnForm form = new OwnForm() ;
		add (form);
		OwnAjaxButton saveButton = new OwnAjaxButton("saveButton") {
			@Override
			protected void onSubmit(AjaxRequestTarget target, Form<?> form) {
				closeButton(target);

			}
		};
		saveButton.setVisible(false);
		form.add(saveButton);
		OwnAjaxButton closeButton = new OwnAjaxButton("closeButton") {
			@Override
			protected void onSubmit(AjaxRequestTarget target, Form<?> form) {
				closeButton(target);

			}
		};
		form.add(closeButton);

	}

	public void closeButton(AjaxRequestTarget target) {
	}
}
